<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
    var a = 6;
    var b = 5;
    console.log(a.toString(2));//
    console.log(b.toString(2));//
    c = a ^ b;
    console.log(c.toString(2));
</script>
</body>
</html>